#include <memory>
#include <iostream>
#include "include/nat_client.h"

int main() {

    std::shared_ptr<NATClient> clnt(new NATClient());
    try
    {
        clnt->init();
        std::thread cltThread(&NATClient::RecvThreadProc);
        clnt->output_usage();

        while (true)
        {
            char command[COMMANDMAXC];
            std::cin >> command;
            clnt->ParseCommand(command);
        }
    }
    catch(std::exception &e)
    {
        std::cout << "something is error: " << e.what() << std::endl;
        return 1;
    }
}
